#ifndef _GEO_TIFF_WRITER_HXX_
#define _GEO_TIFF_WRITER_HXX_

//#include <GeoTiff/geotiffio.h>
#include <tiff.h>
//#include <xtiffio.h>
#include <tiffio.h>



#include <string.h>
#include <opencv/cv.h>
class GeoTiffImage;

class GeoTiffWriter
{
public:
	GeoTiffWriter();
	~GeoTiffWriter();
public:
	inline void setFileName(char* fn) { strcpy(_fileName, fn); }
	inline const char* getFileName() { return _fileName; }

	inline void setGeoTiffImage(GeoTiffImage* image) { _image = image; }
	inline GeoTiffImage* getGeoTiffImage() { return _image;	}

	void write();
	void write(IplImage* iplImage, GeoTiffImage* tifImage);

private:
	void setUpTIFFDirectory(TIFF *tif);

private:
	char _fileName[256];
	GeoTiffImage* _image;
};
#endif
